package com.atguigu.spring6;


import lombok.Getter;
import lombok.Setter;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

@Getter
@Setter
public class User {

    private final Logger logger = LoggerFactory.getLogger(User.class);
    private String name;


    public User() {
        logger.info("User的无参构造执行了");
    }

    public User(String name) {
        this.name = name;
        logger.info("User的有参构造执行了");
    }


    public void add() {
        logger.info("User的add方法执行了");
    }

}
